﻿using MongoDB.Bson;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace SmallJob.Model
{
    public class MMessage
    {
        public ObjectId Id { get; set; }
        public String ParentID { get; set; }
        public int Type { get; set; }
        public int SenderID { get; set; }
        public int ReceiverID { get; set; }
        public bool IsRead { get; set; }
        public String Content { get; set; }
        private DateTime date;
        public DateTime Date
        {
            get
            {
                return date.ToLocalTime();
            }
            set
            {
                date = value;
            }
        }
        public MMessageEmbedInfo Info { get; set; }

        //just for view not save
        public MConversation Parent { get; set; }
    }
}
